package demo.spring.boot.count;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * Tests
 * <p>
 * Created by chenlushun on 2016/12/8.
 */
@RestController
@RequestMapping("/hello")
public class HelloWordController {

    @Resource(name = "kl")
    private MyService kl;

    /**
     * 一个简单的请求
     */
    @RequestMapping("/word")
    public String sayHello() {
        kl.exampleMethOd();
        System.out.println("hello word");
        return "Hello Word -_-";
    }

}
